package com.zzc.mapper;

import com.zzc.pojo.UserRoleKey;
import org.apache.ibatis.annotations.Param;

public interface UserRoleMapper {
    int deleteByPrimaryKey(UserRoleKey key);

    int insert(UserRoleKey record);

    int insertSelective(UserRoleKey record);

    /**
     * 移除用户权限
     * @param userId
     * @return
     */
    int deleteByUserID(Integer userId);

    /**
     * 批量添加权限
     * @param userId
     * @param roleId
     * @return
     */
    int addUserRole(@Param("userId") Integer userId,@Param("roleId") Integer roleId);
}